<template>
	<view>
		<view class="all">
			<view class="brandBox">
				<view class="topBox">
					<image class="img" :src="img" mode="widthFix"></image>
					<view class="title"><text class="title-text" v-html="title"></text></view>
				</view>
				<view class="bottom" v-html="txt"></view>
			</view>
		</view>
	</view>
</template>

<script>
import { Apibrand } from '@/utils/api.js';
export default {
	data() {
		return {
			id: '',
			img: '',
			title: '',
			txt: ''
		};
	},
	components: {
		Apibrand
	},
	methods: {},
	async onLoad(e) {
		// console.log(e.id);
		this.id = e.id;
		let res = await Apibrand(this.id);
		console.log(res.data.brand);
		this.img = res.data.brand.list_pic_url;
		this.title = res.data.brand.name;
		this.txt = res.data.brand.simple_desc;
	}
};
</script>

<style lang="scss">
.all {
	background-color: #efefef;
	height: 100vh;
	width: 750rpx;
	.brandBox {
		width: 750rpx;
		.topBox {
			position: relative;
			width: 750rpx;
			height: 420rpx;
			.img {
				width: 100%;
			}
			.title {
				position: absolute;
				left: 0;
				top: 0;
				right: 0;
				bottom: 0;
				margin: auto;
				height: 60rpx;
				line-height: 60rpx;
				text-align: center;
				font-size: 40rpx;
				color: #fff;
				width: 100%;
				text-decoration: underline;
				.title-text {
				}
			}
		}
		.bottom {
			width: 750rpx;
			height: 236rpx;
			background-color: #fff;
			padding: 40rpx 20rpx;
			font-size: 36rpx;
			text-align: center;
			line-height: 52rpx;
			color: #666;
			box-sizing: border-box;
		}
	}
}
</style>
